#ifndef __SDRAM_CFG_H
#define __SDRAM_CFG_H

/* 颗粒行数 */
#define	ROW_1K		0x7
#define	ROW_2K		0x0
#define	ROW_4K		0x1
#define	ROW_8K		0x2
#define	ROW_16K		0x3
/* 颗粒列数 */
#define	COL_256		0x7
#define	COL_512		0x0
#define	COL_1K		0x1
#define	COL_2K		0x2
#define	COL_4K		0x3
/* 颗粒位宽 */
#define	WIDTH_8		0x0
#define	WIDTH_16	0x1
#define	WIDTH_32	0x2

#if defined(CONFIG_SDRAM_K4S510832D)
#define	SDRAM_ROW		ROW_8K
#define	SDRAM_COL		COL_2K
#define	SDRAM_WIDTH		WIDTH_8
#define	SDRAM_SIZE		0x04000000	//64MByte
#elif defined(CONFIG_SDRAM_K4S511632B)
#define	SDRAM_ROW		ROW_8K
#define	SDRAM_COL		COL_1K
#define	SDRAM_WIDTH		WIDTH_16
#define	SDRAM_SIZE		0x04000000	//64MByte
#elif defined(CONFIG_SDRAM_MT48LC32M16A2)
#define	SDRAM_ROW		ROW_8K
#define	SDRAM_COL		COL_1K
#define	SDRAM_WIDTH		WIDTH_16
#define	SDRAM_SIZE		0x04000000	//64MByte
#elif defined(CONFIG_SDRAM_EM63A165TS)
#define	SDRAM_ROW		ROW_8K
#define	SDRAM_COL		COL_512
#define	SDRAM_WIDTH		WIDTH_16
#define	SDRAM_SIZE		0x02000000	//32MByte
#elif defined(CONFIG_SDRAM_V54C3256164VHI6I)
#define	SDRAM_ROW		ROW_8K
#define	SDRAM_COL		COL_512
#define	SDRAM_WIDTH		WIDTH_16
#define	SDRAM_SIZE		0x02000000	//32MByte
#endif

#endif /* __SDRAM_CFG_H */
